In the existing technology, small changes in physical quantities such as length, temperature, refractive index, pressure and so on are usually measured through the optical fiber sensor. A Mach-Zehnder interferometer based optical sensor is a common optical fiber sensor. The measuring principle comprises dividing the laser beam output by the laser into two beams which respectively pass the couplers and come into the two optical fiber arms of the interferometer; uniting the two beams transmitted in the two arms by the couplers to form interference; detecting the light intensity of the interference of the two beams by a detector to determine a phase difference; and determining the measured physical quantity. Because the amounts of optical paths of the two arms can be affected by external conditions such as temperature, pressure and so on, the Mach-Zehnder interferometer can finish the measurement of physical quantities such as optical fiber strain and temperature, and is the important physical basis of many sensors. But such optical fiber sensor detects the phase difference of two beams of laser, the detection precision and sensitivity is still limited and it needs to provide a new type optical sensor of high precision and high sensitivity.